package com.niit.entity.dto;

import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.multipart.MultipartFile;

import java.util.Date;

@Data
@NoArgsConstructor
public class InfoUpdateDTO {
	// 基础信息字段（添加校验注解）
	private String username;
	private String realName;
	private String gender;
	private String email;
	private String description;
	private String idCard;
	// 日期字段保留格式注解
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	private Date birthday;
	private String phone;
	private MultipartFile resumeFile;
	private MultipartFile avatar;
	private Integer companyId;
	private Region region = new Region();  // 必须初始化避免NPE
	private String addressDetail;
	// 嵌套静态类处理层级参数
	@Data
	public static class Region  {
		private Long code;  // 对应 region.code
	}

}
